package com.zany.children.dao;

import com.zany.children.vo.Teacher;

import java.util.List;
import java.util.Map;

public interface TeacherDao {

    List<Teacher> getTeacherListPage(Map<String,Object> teacher);

    Integer getTeacherListPageCount(Map<String,Object> teacher);


    /**
     * 保存老师信息.
     *
     * @param teacher
     * @return
     */
    Long saveTeacher(Teacher teacher);


    /**
     * 修改老师信息.
     *
     * @param teacher
     */
    void updateTeacher(Teacher teacher);


    /**
     * 通过id获取老师信息.
     *
     * @param id
     * @return
     */
    Teacher getTeacherById(Long id);

    /**
     * 保存班级与老师关系.
     * @param classId
     * @param teaId
     * @param creater
     */
    void saveClassTeacherRela(Long classId, Long teaId, String creater);


    /**
     * 通过id删除老师.逻辑删除.
     * @param teaId
     */
    void deleteTeacherById(Long teaId);


    /**
     * 通过tea_id删除关系.
     * @param teaId
     */
    void deleteClassTeacherRelaByTeaId(Long teaId);
}
